home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1995 November / EnigmA AMIGA RUN 02 (1995)(G.R. Edizioni)(IT)[!][issue 1995-11][Skylink CD].iso / earcd / util / text / xes.lha / XES / Install < prev    next >
Text File  |  1995-05-31  |  6KB  |  218 lines

  1. ; Installation script for XES
  2. ; Copyright (c) 1995 Fergus Duniho
  3.  
  4. (transcript "Installing the XDME Excelsior Suite ...")
  5.  
  6. (set @default-dest (getassign "XES"))
  7. (if (> (strlen @default-dest) 0)
  8.     (
  9.         (set response
  10.             (askchoice
  11.                 (prompt
  12.                     "Because I sometimes remove stuff from XES, it is best "
  13.                     "to delete your present XES installation before the "
  14.                     "installation of the present version commences.  Do "
  15.                     "you wish to delete it?"
  16.                 )
  17.                 (help @askchoice-help)
  18.                 (choices "Yes" "No")
  19.             )
  20.         )
  21.         (if (= response 0)
  22.             (run "delete XES:#? ALL")
  23.         )
  24.     )
  25.     (
  26.         (set @default-dest "Work:")
  27.         (set appdir
  28.             (askdir
  29.                 (prompt "In which drawer should the XES drawer reside?")
  30.                 (help @askdir-help)
  31.                 (default @default-dest)
  32.             )
  33.         )
  34.         (set @default-dest (tackon appdir "XES"))
  35.  
  36.         (makedir @default-dest
  37.             (infos)
  38.             (prompt "Creating XES directory")
  39.         )
  40.         (makeassign "XES" @default-dest)
  41.         ; Make changes to the startup sequence
  42.         (working "Modifying the user-startup")
  43.         (startup "XES"
  44.             (prompt "Adding XES: assignment to user-startup")
  45.             (help @startup-help)
  46.             (command "; The XDME Excelsior Suite\n")
  47.             (command "; Copyright (c) 1995 Fergus Duniho.\n")
  48.             (command (cat "Assign XES: " @default-dest "\n"))
  49.         )
  50.     )
  51. )
  52.  
  53. (makedir (tackon @default-dest "S")
  54.     (prompt "Creating S directory")
  55. )
  56. (makedir (tackon @default-dest "GUI")
  57.     (prompt "Creating GUI directory")
  58. )
  59. (makedir (tackon @default-dest "Rexx")
  60.     (prompt "Creating Rexx directory")
  61. )
  62. (makedir (tackon @default-dest "Docs")
  63.     (infos)
  64.     (prompt "Creating Docs directory")
  65. )
  66.  
  67. (copyfiles
  68.     (prompt "Copying XDME scripts")
  69.     (help @copyfiles-help)
  70.     (source "S/")
  71.     (dest (tackon @default-dest "S"))
  72.     (confirm)
  73.     (files)
  74.     (all)
  75. )
  76.  
  77. (copyfiles
  78.     (prompt "Copying Graphical User Interfaces")
  79.     (help @copyfiles-help)
  80.     (source "GUI/")
  81.     (dest (tackon @default-dest "GUI"))
  82.     (confirm)
  83.     (files)
  84.     (all)
  85. )
  86.  
  87. (copyfiles
  88.     (prompt "Copying Documentation")
  89.     (help @copyfiles-help)
  90.     (source "Docs/")
  91.     (dest (tackon @default-dest "Docs"))
  92.     (infos)
  93.     (confirm)
  94.     (all)
  95. )
  96.  
  97. (copyfiles
  98.     (prompt "Copying ARexx Scripts")
  99.     (help @copyfiles-help)
  100.     (source "Rexx/")
  101.     (dest (tackon @default-dest "Rexx"))
  102.     (infos)
  103.     (confirm)
  104.     (all)
  105. )
  106.  
  107. (set @default-dest
  108.     (askdir
  109.         (prompt "Install Paginate where?")
  110.         (help @askdir-help)
  111.         (default "C:")
  112.     )
  113. )
  114.  
  115. (copyfiles
  116.     (prompt "Copying utility programs")
  117.     (help @copyfiles-help)
  118.     (source "C/Paginate")
  119.     (dest @default-dest)
  120.     (confirm)
  121. )
  122.  
  123. (set edrc
  124.     (tackon
  125.         (askdir
  126.             (prompt "In which drawer does (or will) your .edrc file reside?")
  127.             (help @askdir-help)
  128.             (default "S:")
  129.         )
  130.         ".edrc"
  131.     )
  132. )
  133.  
  134. (set response
  135.     (askchoice
  136.         (prompt
  137.             "To make use of XES, your .edrc file must contain a line "
  138.             "which reads: source XES:S/xes.xrc.  If you have your own "
  139.             "macros, keymappings, or settings in your .edrc file, then "
  140.             "you should just add this line to it.  Append it to get the "
  141.             "full benefit of XES, or prepend to give priority to what is "
  142.             "already in your .edrc file.  If you don't have an .erdc file, "
  143.             "or if you are just using one from a previous version of XES, "
  144.             "you should just write a new .edrc file."
  145.         )
  146.         (help @askchoice-help)
  147.         (choices "Append to .edrc" "Prepend to .edrc" "Write new .edrc" "Leave .edrc alone")
  148.     )
  149. )
  150.  
  151. (if (= response 0)
  152.     (run (cat "echo >>" edrc " source XES:S/xes.xrc"))
  153. )
  154.  
  155. (if (= response 1) (
  156.     (run (cat "copy " edrc " t:"))
  157.     (run (cat "echo >" edrc " source XES:S/xes.xrc"))
  158.     (run (cat "type >>" edrc " t:.edrc"))
  159. ))
  160.  
  161. (if (= response 2)
  162.     (run (cat "echo >" edrc " source XES:S/xes.xrc"))
  163. )
  164.  
  165. (if (not (exists "ENV:Diary"))
  166.     (
  167.         (set diarydir
  168.             (askdir
  169.                 (prompt
  170.                     "XES makes special provisions for you to keep a secret diary. "
  171.                     "It expects to find all diary entries in a single drawer. "
  172.                     "This script will create a drawer for you called /Diary/. "
  173.                     "Where do you want the Diary drawer to reside? Please don't "
  174.                     "choose to put it in the XES: drawer, as that drawer may get "
  175.                     "flushed when you update XES again."
  176.                 )
  177.                 (help @askdir-help)
  178.                 (default "Work:")
  179.             )
  180.         )
  181.  
  182.         (set @default-dir (tackon diarydir "Diary/"))
  183.         (makedir @default-dest
  184.             (infos)
  185.             (prompt "Creating Diary directory")
  186.         )
  187.         (run (cat "setenv Diary " @default-dir))
  188.         (run "copy ENV:Diary ENVARC:")
  189.     )
  190. )
  191.  
  192. (if (not (exists "ENV:MyName"))
  193.     (
  194.         (set name
  195.             (askstring
  196.                 (prompt
  197.                     "To mark your diary entries as yours, XES also needs to "
  198.                     "know what name you wish to be referred to at the "
  199.                     "beginning of each diary entry. You probably want to "
  200.                     "enter your first name and last. What name do you want "
  201.                     "to appear in your diary entries?"
  202.                 )
  203.                 (help @asktstring-help)
  204.             )
  205.         )
  206.  
  207.         (run (cat "setenv MyName " name))
  208.         (run "copy ENV:MyName ENVARC:")
  209.     )
  210. )
  211.  
  212. (message
  213.     "The XDME Excelsior Suite has been successfully installed. "
  214.     "It will be available to you the next time you use XDME."
  215. )
  216.  
  217. (exit (quiet))
  218.